/* 
 * File:   GameStatus.h
 * Author: jose
 *
 * Created on March 30, 2012, 7:19 PM
 * 
 * 
 * -0-|-1-|-2-
 * -3-|-4-|-5-
 * -6-|-7-|-8-
 *
 */

#ifndef GAMESTATUS_H
#define	GAMESTATUS_H

#include <vector>

class GameStatus {
public:
    GameStatus();
    GameStatus(const GameStatus& orig);
    virtual ~GameStatus();
    enum player{ PLAYER_ONE=1, PLAYER_TWO=2, PLAYER_NONE=0 };
    bool setPlayerAtPosition(player player, int position);
    bool isPositionEmpty(int position);
    player getWinner();
    bool isGameFinished();
    enum gameStates {    STATE_NULL,    STATE_INTRO,    STATE_PLAYING,    STATE_END_GAME,    STATE_QUIT };
    gameStates currState;
    gameStates nextState;
    void setNextState(gameStates newState);
    gameStates getNewState();
    int numberOfPlayers;
    std::vector<player> getGameBoard();
private:
    //a vector that will represent the board with 9 positions starting empty
    std::vector<player> gameBoard;
    player winnerPlayer;

};

#endif	/* GAMESTATUS_H */

